import request from '@/utils/request'

export function list(data) {
  return request({
    url: 'order/index',
    method: 'post',
    data
  })
}
export function clearList(data) {
  return request({
    url: 'order/clearList',
    method: 'post',
    data
  })
}
export function finishClearList(data) {
  return request({
    url: 'order/finishClearList',
    method: 'post',
    data
  })
}

export function joinList(data) {
  return request({
    url: 'order/joinList',
    method: 'post',
    data
  })
}

export function exportOrder(data) {
  return request({
    url: 'order/exportOrder',
    method: 'post',
    data
  })
}

export function exportOrderGoods(data) {
  return request({
    url: 'order/exportOrderGoods',
    method: 'post',
    data
  })
}

export function exportClearOrder(data) {
  return request({
    url: 'order/exportClearOrder',
    method: 'post',
    data
  })
}

export function exportClearOrderGoods(data) {
  return request({
    url: 'order/exportClearOrderGoods',
    method: 'post',
    data
  })
}

export function exportFinishClearOrder(data) {
  return request({
    url: 'order/exportFinishClearOrder',
    method: 'post',
    data
  })
}

export function exportFinishClearOrderGoods(data) {
  return request({
    url: 'order/exportFinishClearOrderGoods',
    method: 'post',
    data
  })
}

// 申报海关订单
export function orderPush(data) {
  return request({
    url: 'order/declareOrder',
    method: 'post',
    data
  })
}

// 变更订单信息
export function orderInfo(data) {
  return request({
    url: 'order/edit',
    method: 'post',
    data
  })
}

// 查询海关订单回执
export function orderSelect(data) {
  return request({
    url: 'order/receiptOrder',
    method: 'post',
    data
  })
}

// 申报海关清单
export function orderClearPush(data) {
  return request({
    url: 'order/declareDetailedList',
    method: 'post',
    data
  })
}

// 查询海关清单回执
export function orderClearSelect(data) {
  return request({
    url: 'order/receiptDetailedList',
    method: 'post',
    data
  })
}

// 泰州海关订单申报/变更
export function taizhouPushOrders(data) {
  return request({
    url: 'order/taizhouPushOrders',
    method: 'post',
    data: data
  })
}

// 泰州海关清单申报
export function taizhouPushClearOrders(data) {
  return request({
    url: 'order/taizhouPushClearOrders',
    method: 'post',
    data: data
  })
}

// 删除订单基础数据
export function delOrder(data) {
  return request({
    url: 'order/delOrder',
    method: 'post',
    data: data
  })
}

// 导出订单xml
export function exportOrderXml(data) {
  return request({
    url: 'order/orderXml',
    method: 'post',
    data: data
  })
}

// 导出清单xml
export function exportInventoryXml(data) {
  return request({
    url: 'order/inventoryXml',
    method: 'post',
    data: data
  })
}

// 下载模板
export function downTemplate(data) {
  return request({
    url: 'order/downTemplate',
    method: 'post',
    data: data
  })
}

// 导入物流信息
export function importLogistics(data) {
  return request({
    url: 'order/importLogistics',
    method: 'post',
    data: data
  })
}

export function getXspayList(data) {
  return request({
    url: '/xspay/index',
    method: 'get',
    params: data
  })
}
